From 8fd4fe03b4745b7c6e89eacd71b211d7b988ffcf Mon Sep 17 00:00:00 2001 From: Alex Crichton Date: Thu, 5 Jan 2017 10:04:12 -0800 Subject: [PATCH] Try using before_deploy on AppVeyor --- appveyor.yml | 24 +++++++++++------------- 1 file changed, 11 insertions(+), 13 deletions(-) diff --git a/appveyor.yml b/appveyor.yml index 8980df29d..0ab8748b9 100644 --- a/appveyor.yml +++ b/appveyor.yml @@ -49,18 +49,16 @@ cache: - target - C:\Users\appveyor\.cargo\registry -after_test: - - ps: New-Item -Path "${env:APPVEYOR_REPO_COMMIT}" -ItemType "directory" - - ps: New-Item -Path "target" -ItemType "directory" -Force - - ps: New-Item -Path "target/${env:TARGET}" -ItemType "directory" -Force - - ps: New-Item -Path "target/${env:TARGET}/release" -ItemType "directory" -Force - - ps: New-Item -Path "target/${env:TARGET}/release/dist" -ItemType "directory" -Force - - ps: Get-ChildItem -Path target\${env:TARGET}\release\dist -Filter '*.tar.gz' | Move-Item -Destination ${env:APPVEYOR_REPO_COMMIT} - - ps: Get-FileHash .\${env:APPVEYOR_REPO_COMMIT}\* | ForEach-Object {[io.file]::WriteAllText($_.Path + ".sha256", $_.Hash.ToLower() + "`n")} - -artifacts: - - path: $(APPVEYOR_REPO_COMMIT)\cargo-* - name: cargo +before_deploy: + - ps: | + New-Item -Path deploy -ItemType directory + Get-ChildItem -Path target\${env:TARGET}\release\dist -Filter '*.tar.gz' | Move-Item -Destination deploy + Get-FileHash .\deploy\* | ForEach-Object { + [io.file]::WriteAllText($_.Path + ".sha256", $_.Hash.ToLower() + "`n") + } + Get-ChildItem -Path deploy | Foreach-Object { + Push-AppveyorArtifact $_.FullName -FileName ${env:APPVEYOR_REPO_COMMIT}/$_.BaseName + } deploy: - provider: S3 @@ -71,7 +69,7 @@ deploy: bucket: rust-lang-ci set_public: true region: us-east-1 - artifact: cargo folder: cargo-builds + artifact: /.*\.(tar.gz|sha256)/ on: branch: auto-cargo -- 2.30.2